<?php
class Check
{
	public function isAdmin()
	{
		if($_SESSION['session'] == 1) return true;
		else return false;
	}
}
class jQuery
{
	function alert($string) {
	if(!empty($string)) {
		$string = str_replace("<p>", "", $string);
		$string = str_replace("</p>", "<br>", $string);
		$thing = '<div class="ui-widget">
				<div class="ui-state-highlight ui-corner-all" style="margin-top: 20px; padding: 0 .7em; font-size: 12px;"> 
					<p><span class="ui-icon ui-icon-info" style="float: left; margin-right: .3em; color:black;"></span>
					<strong>Alert:</strong><br>'.$string.'</p>
				</div>
			</div><br />';
		return $thing;
		}
	}
	
	//jQuery success dialog
	function success($string) {
	if(!empty($string)) {
		$string = str_replace("<p>", "", $string);
		$string = str_replace("</p>", "<br>", $string);
		$thing = '<div class="ui-widget">
				<div class="ui-state-highlight ui-corner-all" style="margin-top: 20px; padding: 0 .7em; font-size: 12px; border-color: green; background: #ecfde8;"> 
					<p><span class="ui-icon ui-icon-info" style="float: left; margin-right: .3em; color:black;"></span>
					<strong>Success:</strong><br>'.$string.'</p>
				</div>
			</div><br />';
		return $thing;
		}
	}
}
?>